//
//  AboutView.m
//  Trading365
//
//  Created by yifei tong on 12-1-11.
//  Copyright (c) 2012年 dhc. All rights reserved.
//

#import "AboutView.h"
#import "Type.h"

@implementation AboutView
@synthesize logoPic;

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)didReceiveMemoryWarning
{
    // Releases the view if it doesn't have a superview.
    [super didReceiveMemoryWarning];
    
    // Release any cached data, images, etc that aren't in use.
}

#pragma mark - View lifecycle

- (void)viewDidLoad
{
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    [self.view setBackgroundColor:BACKGROUND_COLOR];

    logoPic.userInteractionEnabled=YES;
    UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(picTapped)];
    [logoPic addGestureRecognizer:singleTap];
    [singleTap release];

}

- (void)viewDidUnload
{
    [self setLogoPic:nil];
    [super viewDidUnload];
    // Release any retained subviews of the main view.
    // e.g. self.myOutlet = nil;
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    // Return YES for supported orientations
    return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

-(IBAction)MoreInfo:(id)sender
{
    [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://www.maoyi365.com.cn"]];
}

-(void)picTapped
{
    [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://www.maoyi365.com.cn"]];    
}


- (void)dealloc {
    [logoPic release];
    [super dealloc];
}
@end
